<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>学生编辑页面</title>
</head>
<body>
<h1>学生编辑页面</h1>
<form action="/edit_student/" method="post">
    <input type="hidden" name="sid" value="{{ sname.id }}">
    <input type="text" name="sname" value="{{ sname.sname }}">
    <p>所在班级
        <select name="class_id">
            {% for class_one in class_list %}
                {% if class_name.cname == class_one.cname %}
                    <option selected value="{{ class_one.id }}">{{ class_one.cname }}</option>
                {% else %}
                    <option value="{{ class_one.id }}">{{ class_one.cname }}</option>
                {% endif %}
            {% endfor %}
        </select>
    </p>
    <input type="submit" value="提交">
</form>

</body>
</html>